package com.gopay.common.domain.bank;

import java.util.Date;

import javax.persistence.*;

import com.gopay.common.domain.BaseEntity;

/**
 * @ClassName: CustAppInfo
 * @Description: 商户应用关联表 实体类
 * @author lx
 * @date 2016年9月22日 下午5:46:11
 */
@Entity
@Table(name = "CUST_APP_INFO")
public class CustAppInfo extends BaseEntity {

    private static final long serialVersionUID = 6948479070575715413L;

    /**
     * @Fields STATUS_EFFECT : 生效
     */
    public static final String STATUS_EFFECT = "01";

    /**
     * @Fields STATUS_EXPIRE : 失效
     */
    public static final String STATUS_EXPIRE = "02";

    /**
     * @Fields id : 主键
     */
    @Id
    @SequenceGenerator(name = "CUST_APP_INFO_GENERATOR", sequenceName = "CUST_APP_INFO_SEQ")
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "CUST_APP_INFO_GENERATOR")
    @Column(name = "ID")
    private long id;

    /**
     * @Fields custId : 用户ID
     */
    @Column(name = "CUST_ID", length = 10)
    private String custId;

    /**
     * @Fields intrfaceChannelCode : APP支付通道CODE
     */
    @Column(name = "INTRFACE_CHANNEL_CODE", length = 2)
    private String intrfaceChannelCode;

    /**
     * @Fields appName : 应用名称
     */
    @Column(name = "APP_NAME", length = 50)
    private String appName;

    /**
     * @Fields appId : 应用ID
     */
    @Column(name = "APP_ID", length = 32)
    private String appId;

    /**
     * @Fields merchantId : 三方平台商户号
     */
    @Column(name = "MERCHANT_ID", length = 50)
    private String merchantId;

    /**
     * @Fields merchantKey : 三方平台商户密钥
     */
    @Column(name = "MERCHANT_KEY", length = 50)
    private String merchantKey;

    /**
     * @Fields status :01 生效 02 失效
     */
    @Column(name = "STATUS", length = 2)
    private String status;

    /**
     * @Fields createdTs : 创建时间
     */
    @Column(name = "CREATED_TS")
    private Date createdTs;

    /**
     * @Fields createOperId : 创建人
     */
    @Column(name = "CREATE_OPER_ID", length = 10)
    private String createOperId;

    /**
     * @Fields lastUpdOperId : 修改人
     */
    @Column(name = "LAST_UPD_OPER_ID", length = 10)
    private String lastUpdOperId;

    /**
     * @Fields lastUpdTs : 修改时间
     */
    @Column(name = "LAST_UPD_TS")
    private Date lastUpdTs;

    /**
     * @Fields serialVersionUID : 乐观锁版本号
     */
    @Version
    @Column(name = "VERSION", nullable = false, precision = 22, scale = 0)
    private int version;

    @Transient
    private String channelName;

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public String getCustId() {
        return custId;
    }

    public void setCustId(String custId) {
        this.custId = custId;
    }

    public String getIntrfaceChannelCode() {
        return intrfaceChannelCode;
    }

    public void setIntrfaceChannelCode(String intrfaceChannelCode) {
        this.intrfaceChannelCode = intrfaceChannelCode;
    }

    public String getAppName() {
        return appName;
    }

    public void setAppName(String appName) {
        this.appName = appName;
    }

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getMerchantId() {
        return merchantId;
    }

    public void setMerchantId(String merchantId) {
        this.merchantId = merchantId;
    }

    public String getMerchantKey() {
        return merchantKey;
    }

    public void setMerchantKey(String merchantKey) {
        this.merchantKey = merchantKey;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public Date getCreatedTs() {
        return createdTs;
    }

    public void setCreatedTs(Date createdTs) {
        this.createdTs = createdTs;
    }

    public String getCreateOperId() {
        return createOperId;
    }

    public void setCreateOperId(String createOperId) {
        this.createOperId = createOperId;
    }

    public String getLastUpdOperId() {
        return lastUpdOperId;
    }

    public void setLastUpdOperId(String lastUpdOperId) {
        this.lastUpdOperId = lastUpdOperId;
    }

    public Date getLastUpdTs() {
        return lastUpdTs;
    }

    public void setLastUpdTs(Date lastUpdTs) {
        this.lastUpdTs = lastUpdTs;
    }

    public int getVersion() {
        return version;
    }

    public void setVersion(int version) {
        this.version = version;
    }

    public String getChannelName() {
        return channelName;
    }

    public void setChannelName(String channelName) {
        this.channelName = channelName;
    }
}
